<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<!DOCTYPE html>
<html>
<head>
   <meta charset="utf-8"> 
   <title>宇桥网站内容管理系统-模板管理</title>
   <link rel="stylesheet" href="css/bootstrap.min.css">
   <link rel="stylesheet" href="css/bootstrap-table.min.css">
   <script type="text/javascript" src="js/bootstrap-table.min.js"></script>
   <script type="text/javascript" src="js/bootstrap-table-zh-CN.min.js"></script>
   <script type="text/javascript" src="js/template.js"></script>
</head>
<body>
<div class="container">
	<div class="row clearfix">
		<div class="col-md-3 column">
			<div class="list-group">
				 <a class="list-group-item active" href="#">模板管理</a>
				<div class="list-group-item">
					模板管理
				</div>
			</div>
		</div>
		<div class="col-md-9 column">
		
    <button id="btn_importtemplate" type="button" class="btn btn-primary btn-xs">导入模板 </button>
    <button id="btn_exporttemplate" type="button" class="btn btn-primary btn-xs">导出模板 </button> 
    <button id="btn_addtemplate" type="button" class="btn btn-primary btn-xs">新增模板 </button>
    <!--存放工具栏-->
    <div id="toolbar"></div>
    <!--存放生成的表格-->
    <table id="searchResults" class="table table-hover">
    </table>

			
	<!-- 触发新增/修改模板-->
		<form action="" id="templateForm">
			<div class="modal fade" id="myModal" role="dialog" aria-hidden=true aria-labelledby="myModalLabel">
				<div class="modal-dialog modal-lg">
					<div class="modal-content">
						<div class="modal-header">
							 <button id="btn_close" class="close" aria-hidden="true" type="button" data-dismiss="modal">&times;</button>
							<h4 class="modal-title" id="myModalLabel">新增模板</h4>
						</div>
						<div class="modal-body" >
					
  <input type="hidden" id="templateid"  name="templateid" />
  
  <div class="form-group">
  <label for="templatename" class="sr-only">模板名称</label>
  <input type="text" id="templatename" name="templatename" class="form-control"  placeholder="模板名称" required autofocus>
  </div>
  <div class="form-group">
  <label for="templatecontent" class="sr-only">模板内容</label>
  <textarea id="templatecontent" name="templatecontent" class="form-control" rows="16" style="min-width: 90%" required></textarea>
  </div>
</div>
<div class="modal-footer">
<button id="btn_cancel" class="btn btn-default" type="button" data-dismiss="modal">关闭</button>
<button id="btn_submit" class="btn btn-primary" type="button" >保存</button>
</div>
</div>
</div>
			</div>
		
</form>
<!-- 弹出窗体 -->

	<!-- 触发导入模板-->
		<form action="" id="uploadform">
			<div class="modal fade" id="uploadModal" role="dialog" aria-hidden=true aria-labelledby="uploadModalLabel">
				<div class="modal-dialog modal-lg">
					<div class="modal-content">
						<div class="modal-header">
							 <button id="btn_close" class="close" aria-hidden="true" type="button" data-dismiss="modal">&times;</button>
							<h4 class="modal-title" id="uploadModalLabel">导入模板</h4>
						</div>
	<div class="modal-body" >
		<div class="form-group">
		<label for="importfile">选择文件</label>
		<input type="file" id="importfile" name="importfile" accept=".zip" required>
		</div>
	</div>
<div class="modal-footer">
<button id="btn_cancel" class="btn btn-default" type="button" data-dismiss="modal">关闭</button>
<button id="btn_upload" class="btn btn-primary" type="button" >导入</button>
</div>
</div>
</div>
			</div>
		
</form>
<!-- 弹出窗体 -->


		</div>
	</div>
</div>

</body>
</html>